package com.healthy.mapper;

import com.healthy.entity.Knowledgevaset;
import org.apache.ibatis.annotations.*;

import java.util.List;

public interface KnowledgevasetMapper {
    //    查询所有
    @Select("select * from t_knowledgevaset")
    List<Knowledgevaset> culist();

    //    添加
    @Insert("insert into t_knowledgevaset (type, open) values ( #{knowledgevaset.type}, #{knowledgevaset.open})")
    int cuInsert(@Param("knowledgevaset") Knowledgevaset knowledgevaset);

    //删除
    @Delete("delete from t_knowledgevaset where id = #{id}")
    int cuDeleteByid(int id);

    //修改
    @Update("update t_knowledgevaset set type = #{type}, open = #{open} where id = #{id}")
    int cuUpdateByid(@Param("id") int id,@Param("type") String type,@Param("open") String open);

}
